import request from '@/utils/request'

export function fetchList(query) {
  return request({
    url: '/api/user/list',
    method: 'get',
    params: query
  })
}

export function fetchOwnerList(query) {
  return request({
    url: '/api/user/owner-options',
    method: 'get',
    params: query
  })
}

export function fetchManagerOptions(query) {
  return request({
    url: '/api/user/manager-options',
    method: 'get',
    params: query
  })
}

export function updateUser(data) {
  return request({
    url: '/api/user/update-user-state',
    method: 'post',
    data
  })
}
